<?php
include_once 'DATABASE.interface.cls.php'; 
class DBCORE{
	var $db_type;
	var $db;
	function __construct() {
	}
	function db_connect($host, $user, $pass, $dbase) {
		$this->db_type = "mysql";
		include_once 'DATABASE.'.$this->db_type.'.cls.php';
		$this->db = new DATABASE();
		$this->db->db_connect($host, $user, $pass, $dbase);
	}
	function db_query($query) {
		return $this->db->db_query($query);
	}
	function db_fetch_array($query){
		return $this->db->db_fetch_array($query);
	}
	function db_num_rows($query){
		return $this->db->db_num_rows($query);
	}
	function db_fetch_assoc($query){
		return $this->db->db_fetch_assoc($query);
	}
	function db_affected_rows(){
		return $this->db->db_affected_rows();
	}
	function db_real_escape_string($query){
		return $this->db->db_real_escape_string($query);
	}
	function _close(){
		mysql_close();
	}
	function db_insert_id(){
		return $this->db->db_insert_id();
	}
	/*function __destruct()
	{
		$this->_close();
	}*/
}
?>